import { DEFAULT_LAYOUT } from '../base';
import { AppRouteRecordRaw } from '../types';

const CUSTOMER: AppRouteRecordRaw = {
  path: '/finance',
  name: 'finance',
  component: DEFAULT_LAYOUT,
  meta: {
    locale: 'menu.finance.management',
    requiresAuth: true,
    icon: 'icon-stamp',
    order: 0,
  },
  children: [
    {
      path: '/finance/list',
      name: 'FinanceList',
      component: () => import('@/views/finance/index.vue'),
      meta: {
        locale: 'menu.finance.list',
        requiresAuth: true,
        roles: ['*'],
      },
    },
    {
      path: '/finance/settlement/detail/:id',
      name: 'FinanceSettlementDetail',
      component: () => import('@/views/finance/settlement/detail/index.vue'),
      meta: {
        locale: 'menu.finance.settlement.detail',
        requiresAuth: true,
        roles: ['*'],
        hideInMenu: true,
      },
    },
  ],
};

export default CUSTOMER;
